﻿using DataModels.Models;
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.Text;

namespace ReportingManagement.Components.DHIS
{
    public class DatasetsLink : ModelBase
    {
        private string _id;
        private ReportDataLocation _ReportDataElement;

        public ReportDataLocation ReportDataElement 
        {
            get { return _ReportDataElement; }
            set
            {
                _ReportDataElement = value;
                OnPropertyChanged("ReportDataElement");
            }
        }

        /// <summary>
        /// DHIS data element id
        /// </summary>
        public string id 
        {
            get { return _id; }
            set
            {
                _id = value;
                OnPropertyChanged("id");
            }
        }

    }

    public class ReportDatasetLinkViewModel : ModelBase
    {
        private int _ReportId;
        private string _DatasetId;
        private ObservableCollection<DatasetsLink> _DatasetsElementLinks;

        public int ReportId 
        {
            get { return _ReportId; }
            set
            {
                _ReportId = value;
                OnPropertyChanged("ReportId");
            }
        }

        public string DatasetId 
        {
            get { return _DatasetId; }
            set
            {
                _DatasetId = value;
                OnPropertyChanged("DatasetId");
            }
        }

        public ObservableCollection<DatasetsLink> DatasetsElementLinks 
        {
            get { return _DatasetsElementLinks; }
            set
            {
                _DatasetsElementLinks = value;
                OnPropertyChanged("DatasetsElementLinks");
            }
        }
    }
}
